<?php

namespace frontend\modules\yii2\widgets\layouts\anchor;

use frontend\modules\yii2\widgets\layouts\anchor\assets\AnchorAsset;
use yii\base\Widget;

/**
 * A menu imitate the sidebar of https://docs.docker.com/get-started/
 *
 * @note It's depend on bootstrap;
 *
 * @example :
 * ```php

 * ```
 * @author chenzhiwei <chenzhiweiwk@qq.com>
 * @date   2021/08/31
 */
class Anchor extends Widget
{

    public $class = "cms-anchor bs-docs-sidebar";
    public $style = "";

    public function init()
    {
        parent::init(); // TODO: Change the autogenerated stub
        AnchorAsset::register($this->getView());
    }

    public function run()
    {
        return "<div class='{$this->class}' id='cms-anchor'><ul class='nav nav-sidebar'></ul></div>";
    }

}
